#include<stdio.h>
#include<stdlib.h>
#include<time.h>
#include<string.h>

int generateRandomNUmber(int lower,int upper){
	return (rand()%(upper-lower+1))+lower;
}

int calculate(int num1,int num2,char op){
	int result;
	switch(op){
	case'+':
		result=num1+num2;
		break;
	case'-':
		result=num1-num2;
		break;
	case'/':
		result=num1/num2;
		break;
	}
	return result;
}

int main(){
	int i;
	char userName[20];
	char password[20];
	int score=0;
	printf("欢迎使用小学生测验程序\n");
	do{
		printf("请输入用户名：");
		scanf("%s",userName);
		printf("请输入密码：");
		scanf("%s",password);
		if(strcmp(userName,"admin")!=0||strcmp(password,"admin")!=0){
			printf("用户名或密码错误，请重新登录！\n");
		}
	}while(strcmp(userName,"admin")!=0||strcmp(password,"admin")!=0);
	printf("\n登录成功！开始答题!\n");
	
}
